package com.hnev.interfacedomo3;

public class InterfaceDemo {
	
	public void testStart(IVehicle vehicle){
		vehicle.start();
	}
	
	public static void main(String[] args) {
		InterfaceDemo demo = new InterfaceDemo();
		demo.testStart(new IVehicle() {
			
			@Override
			public void stop() {
				System.out.println("my stop");
			}
			
			@Override
			public void start() {
				System.out.println("my start");
			}
		});
	}

}
